A solar cell includes a p-type doped absorber layer and an n-type doped buffer layer. For some superstrate solar cells, the absorber layer is deposited at a high temperature after the buffer layer (e.g., CdS) is formed. However, there is a cross-diffusion of elements between the buffer layer and the absorber layer during the deposition of the absorber layer at a high temperature.